home *** CD-ROM | disk | FTP | other *** search
/ CD ROM Paradise Collection 4 / CD ROM Paradise Collection 4 1995 Nov.iso / program / swaga_c.zip / ANSI.SWG / 0006_ANSI Ouput w- INT29.pas < prev    next >
Pascal/Delphi Source File  |  1993-05-28  |  650b  |  26 lines

  1. {
  2. ROBERT ROTHENBURG
  3.  
  4. For those interested in using ANSI in Turbo Pascal (at least Dos v2-5
  5. ...I don't know if Dos 6 Uses this routine--Interrupt $29--or not)
  6. here's a tip:  The "undocumented" Fast PutChar interrupt is used by
  7. ANSI.SYS, and thus anything you send to that interrupt will be
  8. ANSI-interpreted (provided ANSI.SYS is loaded :).
  9.  
  10. Use this routine to output a Character to ANSI:
  11. (you'll have to modify it to output Strings, of course).
  12. }
  13.  
  14. Uses
  15.   Dos;
  16.  
  17. Procedure FastPutChar(C : Char);
  18. { Outputs only to "display", not stdout! Uses Dos v2-5. }
  19. Var
  20.   Reg : Registers;
  21. begin
  22.   Reg.AL := Ord(C);
  23.   Intr($29, Reg)
  24. end;
  25.  
  26.